<?php

class Bootstrap extends Zend_Application_Bootstrap_Bootstrap
{
	public function _initView()
	{
		$view = new Zend_View();
		$view->docType('XHTML1_TRANSITIONAL');
		$view->headTitle('Misha Shop Admin');
		$view->headMeta()->appendHttpEquiv('Content-Type', 'text/html; charset=UTF-8')
			->appendHttpEquiv('X-UA-Compatible', 'IE=Edge');
		$view->headScript()->appendFile('/js/jquery-1.8.2.min.js', 'text/javascript')
			->appendFile('/js/jquery-ui-1.9.0.custom.min.js', 'text/javascript')
			->appendFile('/js/common.js', 'text/javascript')
			->appendFile('/js/AjaxDialog.jquery.js', 'text/javascript');
		return $view;
	}
	
	public function _initNavigation()
	{
		$config = new Zend_Config_Xml(APPLICATION_PATH . '/configs/navigation.xml');
		//var_dump($config->toArray());
		$navigation = new Zend_Navigation($config);
		$this->bootstrap('layout');
		$layout = $this->getResource('layout');
		$view = $layout->getView();
		$view->navigation($navigation);
		//$view->menu = $navigation;
		
		//var_dump($navigation->current());
	}
}

